package com.xiaoma.pattern.proxy.cglib;

public class CglibTest {

    public static void main(String[] args) {

        try {
            CglibMeipo cglibMeipo = new CglibMeipo();
            ZhangSan zhangSan = new ZhangSan();
            //生成的是ZhangSan的子类
            ZhangSan obj = (ZhangSan)cglibMeipo.getInstance(ZhangSan.class);
            obj.findLove();
            System.out.println("--------------------------------");
        } catch (Exception e) {
            e.printStackTrace();
        }

    }
}
